package main

import "fmt"
import "net/http"
import "io/ioutil"

func main() {
	resp, err := http.Get("http://example.com/")
	if err != nil {
		panic(err)
	}
	// The client must close the response body when finished
	defer resp.Body.Close()
	body, err := ioutil.ReadAll(resp.Body)
	if err != nil {
		panic(err)
	}
	fmt.Println(resp)
	// fmt.Println(body) // body is bytes
	fmt.Printf("%s", body)
}
